package com.wuliu.driver.service;

import com.wuliu.driver.mapper.FreightsourcesMapper;
import com.wuliu.driver.pojo.Freightsources;
import com.wuliu.driver.pojo.Route;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;
import java.util.Map;

@Service
public class FreightsourcesServiceImpl implements FreightsourcesService{
    @Autowired
    private FreightsourcesMapper freightsourcesMapper;
    @Override
    public List<Freightsources> selectAll() {
        return freightsourcesMapper.selectAll();
    }

    @Override
    public List<Route> selectRoute(Integer id) {
        return freightsourcesMapper.selectRoute(id);
    }

    @Override
    public int deleroute(Integer id) {
        int deleroute = freightsourcesMapper.deleroute(id);
        return deleroute;
    }

    @Override
    public List<Map> selectss(String name) {
        List<Map> selectss = freightsourcesMapper.selectss(name);
        return selectss;
    }

    @Override
    public List<Freightsources> selezhuanshu(Integer id) {
        List<Freightsources> selezhuanshu = freightsourcesMapper.selezhuanshu(id);
        return selezhuanshu;
    }

    @Override
    public int inchang(Route route) {
        int inchang = freightsourcesMapper.inchang(route);
        return inchang;
    }
}
